﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ProductPack.aspx.cs" Inherits="ZX.WebApp.Crm.Hodometer.ProductPack" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title></title>
    <link rel="stylesheet" type="text/css" href="../../scripts/yui_2.9.0/build/container/assets/skins/sam/container.css" />
    <link rel="stylesheet" type="text/css" href="../../scripts/yui_2.9.0/build/button/assets/skins/sam/button.css" />
    <link rel="stylesheet" type="text/css" href="../../scripts/yui_2.9.0/build/layout/assets/skins/sam/layout.css" />
    <link rel="stylesheet" type="text/css" href="../../scripts/yui_2.9.0/build/resize/assets/skins/sam/resize.css" />
    <link rel="stylesheet" type="text/css" href="../../Scripts/yui_2.9.0/build/datatable/assets/skins/sam/datatable.css" />
    <link href="../../Styles/base.css" rel="stylesheet" type="text/css" />
    <script src="../../Scripts/jquery-1.6.min.js" type="text/javascript"></script>
    <script src="../../Scripts/jquery.json-2.2.js" type="text/javascript"></script>
    <script src="../../Scripts/Jquery.form.js" type="text/javascript"></script>
    <script src="../../Scripts/CombinButton.js" type="text/javascript"></script>
    <script type="text/javascript" src="../../Scripts/yui_2.9.0/build/yahoo-dom-event/yahoo-dom-event.js"></script>
    <script type="text/javascript" src="../../Scripts/yui_2.9.0/build/element/element-min.js"></script>
    <script type="text/javascript" src="../../Scripts/yui_2.9.0/build/datasource/datasource-min.js"></script>
    <script type="text/javascript" src="../../Scripts/yui_2.9.0/build/json/json-min.js"></script>
    <script type="text/javascript" src="../../Scripts/yui_2.9.0/build/connection/connection-min.js"></script>
    <script type="text/javascript" src="../../Scripts/yui_2.9.0/build/get/get-min.js"></script>
    <script type="text/javascript" src="../../Scripts/yui_2.9.0/build/dragdrop/dragdrop-min.js"></script>
    <script type="text/javascript" src="../../Scripts/yui_2.9.0/build/datatable/datatable-min.js"></script>
    <script type="text/javascript" src="../../Scripts/yui_2.9.0/build/paginator/paginator-min.js"></script>
    <script type="text/javascript" src="../../scripts/yui_2.9.0/build/layout/layout-min.js"></script>
    <script type="text/javascript" src="../../scripts/yui_2.9.0/build/button/button-min.js"></script>
    <script type="text/javascript" src="../../scripts/yui_2.9.0/build/container/container-min.js"></script>
    <script type="text/javascript" src="../../scripts/yui_2.9.0/build/resize/resize-min.js"></script>
    <script type="text/javascript" src="../../scripts/yui_2.9.0/build/event-delegate/event-delegate-min.js"></script>
    <link href="../../Styles/extendTable.css" rel="stylesheet" type="text/css" />
</head>
<script src="../../Scripts/Appjs/model.AddProductPack.Extend.js" type="text/javascript"></script>
<body class="yui-skin-sam">
    <form id="form1" runat="server">
    <div>
        <div id="toolbar" style="margin-top: 12px; text-align: center;">
            <button type="button" id="btnSave" name="btnSave">
                保存</button>
            <button type="button" id="btnClose" name="btnClose">
                取消</button>
        </div>
        <div class="fieldForm" id="fieldForm">
            <table class="tableContent">
                <tr>
                    <td colspan="2" align="center" style="height: 40px; font-weight: bold; font-size: 30px;">
                        产品包
                    </td>
                </tr>
                <tr>
                    <td width="10%">
                        &nbsp; 产品包名称：<span style="color: Red">*</span>
                    </td>
                    <td>
                        <input type="text" runat="server" title="长度不超过40个汉字" maxlength="40" id="Packname"
                            name="Packname" style="width: 70%;" />
                    </td>
                </tr>
                <tr>
                    <td>
                        &nbsp; 备注：
                    </td>
                    <td>
                        <textarea runat="server" id="Remark" title="长度不超过40个汉字" maxlength="40" name="Remark"
                            style="width: 70%; height: 60px;"></textarea>
                    </td>
                </tr>
            </table>
            <div class="extendDiv">
                <div id="con_two_1">
                    <button type="button" id="btnNew1" onclick="handleAdd();" name="btnNew1">
                        新增</button>
                    <button type="button" id="btnDelete1" onclick="handleDelete();" name="btnDelete1">
                        删除</button>
                    <div id="con_1">
                    </div>
                </div>
                <div class="TotalMoneyDiv">
                    总折扣率：
                    <input type="text" runat="server" id="TotalRebate" name="TotalRebate" onkeyup="if(isNaN(value))execCommand('undo')"
                        onchange="TotalRebateChange(this.value)" onafterpaste="if(isNaN(value))execCommand('undo')"
                        style="width: 70px;" />
                </div>
                <div class="TotalMoneyDiv" id="TotalMoneyDiv">
                    <span style="color: Red;">总金额：</span>
                    <input type="text" runat="server" id="TotalMoney" maxlength="10" name="TotalMoney"
                        readonly="readonly" onkeyup="if(isNaN(value))execCommand('undo')" onafterpaste="if(isNaN(value))execCommand('undo')"
                        style="width: 70px;" />
                </div>
            </div>
        </div>
        <input type="hidden" id="ID" runat="server" />
    </div>
    </form>
    <form id="form2" style="display: none" action="../../Extend/AjaxData/CustomOperating.aspx">
    <textarea style="display: none" id="jsonDataContent" rows="2" cols="2" name="jsonDataContent"></textarea>
    </form>
</body>
<script type="text/javascript">
    var Url = "../../Extend/AjaxData/CustomOperating.aspx";
    var flag = "<%=strFlag %>", action = "<% =DataAction %>";
    var btnSave = "", btnClose = "", btnNews1 = "", btnDeletes1 = "";
    var instance = [{"Packname":"","Remark":"","AddUser":"","Addtime":"","AllMoney":"","AllRebate":""}];
    var CrmProduct = [<%=ListCrmProduct %>],CrmListUnitId=[<%=ListUnitId %>],PackDetail=[<%=ListPackDetail %>];
    (function () {
        var Dom = YAHOO.util.Dom,
            Event = YAHOO.util.Event;
        Event.onDOMReady(function () {
            var layout = new YAHOO.widget.Layout({
                units: [
                { position: 'bottom', height: 60, body: 'toolbar', gutter: '1 1 1 1', scroll: null, zIndex: 2 },
                { position: 'center', body: 'fieldForm', gutter: '0 1 1 1', scroll: true }
                ]
            });
            layout.render();
        });
        if(flag=="1"){
            $("#Packname").attr("readonly","readonly");            
            $("#Remark").attr("readonly","readonly");
            $("#TotalRebate").attr("readonly","readonly");
        }
    })();
    //关闭当前页
    var Close = function () {
        window.parent.$("#tabs").tabs('close', '<%=PageTitle %>');
    }
</script>
</html>
